* Treatment 

gen treat = (cid-2)*(-1)


************ DVs

* True-False (True) Zainichi

gen TrueZ = .
replace TrueZ = q2 if treat==1
replace TrueZ = q5 if treat==0
recode TrueZ 2=0


* feeling thermometer toward foreign people

gen ftp_kr = (q10_4 - 1)/10
gen ftp_Z = (q10_6 - 1)/10


* search engine

gen yahoo = (q13==1)
gen google = (q13==2)

gen engine = (q13!=.)
replace engine = 2 if yahoo==1
replace engine = 3 if google==1
recode engine 0=.


**************** Table 1 *****************

* Model 1
reg TrueZ i.treat

* Model 2
reg TrueZ i.treat sex age edu supldp-supjcp

* Model 3
reg TrueZ i.treat##c.ft_kr

* Model 4
reg TrueZ i.treat##c.ft_kr sex age edu supldp-supjcp

* Model 5
reg ftp_kr i.treat

* Model 6
reg ftp_kr i.treat sex age edu supldp-supjcp

* Model 7
reg ftp_Z i.treat

* Model 8
reg ftp_Z i.treat sex age edu supldp-supjcp



**************** Content Analysis **************** 

gen ft_kr3=.
replace ft_kr3=-1 if ft_kr<0.5
replace ft_kr3=0 if ft_kr==0.5
replace ft_kr3=1 if ft_kr>0.5

xtile ft_kr3nq = ft_kr, nq(3)


* recoding urlcoding_q1
* 0: irrelevant or neutral
* 1: negative
* 2: positive

gen urlcoding_q1_3 = urlcoding_q1
recode urlcoding_q1_3 0=.


* recoding urlcoding_q2
* 0: irrelevant or neutral
* 1: negative
* 2: positive

gen urlcoding_q2_3 = urlcoding_q2
recode urlcoding_q2_3 3=0


